//一些诡异的东西
try {
	var ga_userId = " ";
	if(window.passport && window.passport.cookie) {
		ga_userId = passport.cookie.lenovoId;
	}
	(function(i, s, o, g, r, a, m) {
		i['GoogleAnalyticsObject'] = r;
		i[r] = i[r] || function() {
			(i[r].q = i[r].q || []).push(arguments)
		}, i[r].l = 1 * new Date();
		a = s.createElement(o),
			m = s.getElementsByTagName(o)[0];
		a.async = 1;
		a.src = g;
		m.parentNode.insertBefore(a, m)
	})(window, document, 'script', 'https://www.google-analytics.com/analytics.js', 'ga');
	ga('create', 'UA-110299082-1', 'auto', {
		'userId': ga_userId
	});
	ga('require', 'ec');
	ga(function(tracker) {
		var clientId = tracker.get('clientId');
		ga('set', 'dimension1', clientId);
	});
	ga('set', 'dimension2', ga_userId);
	ga('send', 'pageview');
} catch(e) {}

//页面最下面的选择国家
$('.countries_version').mouseover(function() {
	$('#all_countries').show();
})
$('.countries_version').mouseout(function() {
		$('#all_countries').hide();
	})

//更多诡异的东西
	! function(a) {
		"use strict";
		var b, c = a.Base64,
			d = "2.1.8";
		"undefined" != typeof module && module.exports && (b = require("buffer").Buffer);
		var e = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",
			f = function(a) {
				for(var b = {}, c = 0, d = a.length; c < d; c++)
					b[a.charAt(c)] = c;
				return b
			}(e),
			g = String.fromCharCode,
			h = function(a) {
				if(a.length < 2) {
					var b = a.charCodeAt(0);
					return b < 128 ? a : b < 2048 ? g(192 | b >>> 6) + g(128 | 63 & b) : g(224 | b >>> 12 & 15) + g(128 | b >>> 6 & 63) + g(128 | 63 & b)
				}
				var b = 65536 + 1024 * (a.charCodeAt(0) - 55296) + (a.charCodeAt(1) - 56320);
				return g(240 | b >>> 18 & 7) + g(128 | b >>> 12 & 63) + g(128 | b >>> 6 & 63) + g(128 | 63 & b)
			},
			i = /[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,
			j = function(a) {
				return a.replace(i, h)
			},
			k = function(a) {
				var b = [0, 2, 1][a.length % 3],
					c = a.charCodeAt(0) << 16 | (a.length > 1 ? a.charCodeAt(1) : 0) << 8 | (a.length > 2 ? a.charCodeAt(2) : 0);
				return [e.charAt(c >>> 18), e.charAt(c >>> 12 & 63), b >= 2 ? "=" : e.charAt(c >>> 6 & 63), b >= 1 ? "=" : e.charAt(63 & c)].join("")
			},
			l = a.btoa ? function(b) {
				return a.btoa(b)
			} :
			function(a) {
				return a.replace(/[\s\S]{1,3}/g, k)
			},
			m = b ? function(a) {
				return(a.constructor === b.constructor ? a : new b(a)).toString("base64")
			} :
			function(a) {
				return l(j(a))
			},
			n = function(a, b) {
				return b ? m(String(a)).replace(/[+\/]/g, function(a) {
					return "+" == a ? "-" : "_"
				}).replace(/=/g, "") : m(String(a))
			},
			o = function(a) {
				return n(a, !0)
			},
			p = new RegExp(["[À-ß][-¿]", "[à-ï][-¿]{2}", "[ð-÷][-¿]{3}"].join("|"), "g"),
			q = function(a) {
				switch(a.length) {
					case 4:
						var b = (7 & a.charCodeAt(0)) << 18 | (63 & a.charCodeAt(1)) << 12 | (63 & a.charCodeAt(2)) << 6 | 63 & a.charCodeAt(3),
							c = b - 65536;
						return g(55296 + (c >>> 10)) + g(56320 + (1023 & c));
					case 3:
						return g((15 & a.charCodeAt(0)) << 12 | (63 & a.charCodeAt(1)) << 6 | 63 & a.charCodeAt(2));
					default:
						return g((31 & a.charCodeAt(0)) << 6 | 63 & a.charCodeAt(1))
				}
			},
			r = function(a) {
				return a.replace(p, q)
			},
			s = function(a) {
				var b = a.length,
					c = b % 4,
					d = (b > 0 ? f[a.charAt(0)] << 18 : 0) | (b > 1 ? f[a.charAt(1)] << 12 : 0) | (b > 2 ? f[a.charAt(2)] << 6 : 0) | (b > 3 ? f[a.charAt(3)] : 0),
					e = [g(d >>> 16), g(d >>> 8 & 255), g(255 & d)];
				return e.length -= [0, 0, 2, 1][c],
					e.join("")
			},
			t = a.atob ? function(b) {
				return a.atob(b)
			} :
			function(a) {
				return a.replace(/[\s\S]{1,4}/g, s)
			},
			u = b ? function(a) {
				return(a.constructor === b.constructor ? a : new b(a, "base64")).toString()
			} :
			function(a) {
				return r(t(a))
			},
			v = function(a) {
				return u(String(a).replace(/[-_]/g, function(a) {
					return "-" == a ? "+" : "/"
				}).replace(/[^A-Za-z0-9\+\/]/g, ""))
			},
			w = function() {
				var b = a.Base64;
				return a.Base64 = c,
					b
			};
		if(a.Base64 = {
				VERSION: d,
				atob: t,
				btoa: l,
				fromBase64: v,
				toBase64: n,
				utob: j,
				encode: n,
				encodeURI: o,
				btou: r,
				decode: v,
				noConflict: w
			},
			"function" == typeof Object.defineProperty) {
			var x = function(a) {
				return {
					value: a,
					enumerable: !1,
					writable: !0,
					configurable: !0
				}
			};
			a.Base64.extendString = function() {
				Object.defineProperty(String.prototype, "fromBase64", x(function() {
						return v(this)
					})),
					Object.defineProperty(String.prototype, "toBase64", x(function(a) {
						return n(this, a)
					})),
					Object.defineProperty(String.prototype, "toBase64URI", x(function() {
						return n(this, !0)
					}))
			}
		}
		a.Meteor && (Base64 = a.Base64)
	}(window),
	function(a, b, c) {
		a[b] = c()
	}(this, "Util", function() {
		return {
			cookie: {
				get: function(a) {
					var b = document.cookie,
						c = b.indexOf(a + "="),
						d = b.indexOf(";", c);
					return -1 == d && (d = b.length),
						c > -1 ? b.substring(c + a.length + 1, d) : null
				},
				set: function(a, b, c, d, e) {
					var e = e || "/",
						f = "";
					if(c) {
						var g = new Date;
						g.setTime(g.getTime() + 1e3 * c),
							f = "expires=" + g.toGMTString()
					}
					document.cookie = a + "=" + b + ";" + f + ";" + (d ? "domain=" + d : "") + ";path=" + e
				},
				remove: function(a, b, c) {
					this.set(a, "", -1, b, c)
				}
			},
			parseURI: function(a) {
				var b = String(a).replace(/^\s+|\s+$/g, "").match(/^([^:\/?#]+:)?(\/\/(?:[^:@]*(?::[^:@]*)?@)?(([^:\/?#]*)(?::(\d*))?))?([^?#]*)(\?[^#]*)?(#[\s\S]*)?/);
				return b ? {
					href: b[0] || "",
					protocol: b[1] || "",
					authority: b[2] || "",
					host: b[3] || "",
					hostname: b[4] || "",
					port: b[5] || "",
					pathname: b[6] || "",
					search: b[7] || "",
					hash: b[8] || ""
				} : null
			},
			absolutizeURI: function(a, b) {
				function c(a) {
					var b = [];
					return a.replace(/^(\.\.?(\/|$))+/, "").replace(/\/(\.(\/|$))+/g, "/").replace(/\/\.\.$/, "/../").replace(/\/?[^\/]*/g, function(a) {
							"/.." === a ? b.pop() : b.push(a)
						}),
						b.join("").replace(/^\//, "/" === a.charAt(0) ? "/" : "")
				}
				return b = Util.parseURI(b || ""),
					a = Util.parseURI(a || ""),
					b && a ? (b.protocol || a.protocol) + (b.protocol || b.authority ? b.authority : a.authority) + c(b.protocol || b.authority || "/" === b.pathname.charAt(0) ? b.pathname : b.pathname ? (a.authority && !a.pathname ? "/" : "") + a.pathname.slice(0, a.pathname.lastIndexOf("/") + 1) + b.pathname : a.pathname) + (b.protocol || b.authority || b.pathname ? b.search : b.search || a.search) + b.hash : null
			},
			getDomain: function(a) {
				var b = /\/\/([^\/]+)/.exec(a)[1],
					c = b.split(".").slice(-3);
				return /lenovouat\.cn/.test(a) ? /tks\.lenovouat\.cn/.test(b) ? "tks.lenovouat.cn" : /tk\.lenovouat\.cn/.test(b) ? "tk.lenovouat.cn" : /vip\.lenovouat\.cn/.test(b) ? "vip.lenovouat.cn" : "lenovouat.cn" : /lenovouat\.com/.test(a) ? /tks\.lenovouat\.com/.test(b) ? "tks.lenovouat.com" : /tk\.lenovouat\.com/.test(b) ? "tk.lenovouat.com" : /vip\.lenovouat\.com/.test(b) ? "vip.lenovouat.com" : "lenovouat.com" : 2 == c.length ? b : "com" == c[1] ? c.join(".") : c[1] + "." + c[2]
			},
			loadCSS: function(a, b) {
				var c = document.createElement("link");
				c.rel = "stylesheet",
					c.type = "text/css",
					c.href = a,
					document.getElementsByTagName("head")[0].appendChild(c),
					c.onload = c.onreadystatechange = function() {
						this.readyState && !/loaded|complete/.test(this.readyState) || (b && b(),
							c.onload = c.onreadystatechange = null)
					}
			},
			loadJS: function(a, b, c) {
				var d = document.createElement("script");
				d.type = "text/javascript",
					d.src = a,
					d.onload = d.onreadystatechange = function() {
						this.readyState && "loaded" !== this.readyState && "complete" !== this.readyState || (b && "function" == typeof b && b(),
							this.onload = this.onreadystatechange = null,
							this.parentNode.removeChild(this))
					},
					d.onerror = function() {
						c && "function" == typeof c && c(),
							d.onerror = null
					},
					document.getElementsByTagName("head")[0].appendChild(d)
			},
			simulatePlaceholder: function(a, b, c) {
				var c = c || $("body"),
					b = b || "placeholder",
					d = $(document.createElement("div")),
					e = a.position(),
					f = a.width(),
					g = a.outerHeight() + 1;
				return d.addClass(b).css({
						lineHeight: g + "px",
						width: f + "px",
						height: g + "px",
						left: e.left + "px",
						top: e.top + "px"
					}).html(a.attr("data-placeholder")),
					c.append(d),
					a.val() && d.hide(),
					a.on("keyup", function() {
						"" != a.val() ? d.hide() : d.show()
					}).on("blur", function() {
						"" != a.val() ? d.hide() : d.show()
					}).on("focus", function() {
						"" != a.val() ? d.hide() : d.show()
					}),
					d.on("click", function() {
						a.focus()
					}),
					d
			},
			simulateFormSubmit: function(a, b, c, d) {
				var e = [],
					f = !1;
				$("body").append('<iframe class="iframeBridge" style="display: none;" name="iframeBridge"></iframe>'),
					e.push('<form class="simulateForm" style="display: none" target="iframeBridge" method="post" action="' + a + '">'),
					$.each(b, function(a, b) {
						b && e.push('<input name="' + a + '" value="' + b + '" type="hidden"/>')
					}),
					e.push("</form>"),
					$("body").append(e.join("")),
					$(".simulateForm").submit().remove(),
					$(".iframeBridge").removeAttr("name"),
					$(".iframeBridge").on("load", function() {
						var a = new Function("return " + this.contentWindow.name)();
						$(".iframeBridge").remove(),
							f = !0,
							clearTimeout(g),
							c && c(a)
					});
				var g = setTimeout(function() {
					if(f)
						return void clearTimeout(g);
					$(".iframeBridge").remove(),
						d && d()
				}, 2e4)
			},
			formPostSubmit: function(a, b, c) {
				var d = [],
					e = !1;
				$("body").append('<iframe class="iframepost" style="display:none;" name="iframepost"></iframe>'),
					d.push('<form class="postForm" style="display:none;" target="iframepost" method="post" action="' + a + '">'),
					$.each(b, function(a, b) {
						b && d.push('<input name="' + a + '" value="' + b + '" type="hidden"/>')
					}),
					d.push("</form>"),
					$("body").append(d.join("")),
					$(".postForm").submit().remove(),
					$(".iframepost").on("load", function() {
						try {
							var a = new Function("return " + this.contentWindow.name)();
							$(this).remove(),
								e = !0,
								clearTimeout(f),
								c && c(a)
						} catch(b) {
							c && c({})
						}
					});
				var f = setTimeout(function() {
					if(e)
						return void clearTimeout(f);
					$(".iframepost").remove()
				}, 2e3)
			}
		}
	}),
	function(a, b, c) {
		a[b] = c()
	}(this, "LenovoId", function() {
		return {
			lidlogin: function(a, b) {
				var c = {
					lpstgt: a,
					username: b,
					state: "login",
					realm: "shop.lenovo.com.cn"
				};
				window.Util.formPostSubmit(location.protocol + "//passport.lenovo.com/wauthen2/tgtAccess", c, function() {})
			},
			lidlogout: function(a) {
				var b = {
					lpstgt: "",
					username: a,
					state: "logout",
					realm: "shop.lenovo.com.cn"
				};
				window.Util.formPostSubmit(location.protocol + "//passport.lenovo.com/wauthen2/tgtAccess", b, function() {})
			}
		}
	}),
	function(a, b) {
		this[a] = b()
	}("Class", function() {
		var a = function(a) {
				return /\s(\w+)/.exec(Object.prototype.toString.call(a).toLowerCase())[1]
			},
			b = function(a) {
				for(key in a)
					this[key] = a[key];
				return this
			},
			c = function(c, d) {
				var e, f = a(c),
					g = a(d);
				c = "function" == f ? [c] : "object" == f ? (e = c) && [c.constructor || function() {}] : [function() {}],
					e && delete e.constructor,
					d = "function" == g ? (c = c.concat(d.constructor || d)) && d.prototype : "object" == g ? d : null,
					e && !d ? (d = e,
						e = null) : d = d || {},
					d.extended || (d.extended = b);
				var h = function() {
					e && b.call(this, e)
				};
				h.prototype = d;
				var i = function() {
					for(var a = c.length, b = a - 1; b >= 0; b--)
						c[b].apply(this, arguments)
				};
				return i.constructor = c[0],
					i.prototype = new h,
					i.extended = function(d) {
						return d.extended = d.extended || b,
							c = [this.constructor],
							this.prototype = d,
							"function" == a(d) && (c = c.concat(d.constructor || d),
								this.prototype = d.prototype),
							this
					},
					i.implemented = function(a) {
						this.prototype = (new h).extended(a)
					},
					i
			},
			d = {};
		return d.create = c,
			d
	});
var getPosition = function(a, b) {
		for(var c = y = 0, b = b || document.body; a != b;)
			c += a.offsetLeft,
			y += a.offsetTop,
			a = a.offsetParent;
		return {
			x: c,
			y: y
		}
	},
	AutoComplete = Class.create({
		constructor: function(a) {
			var b;
			if(this.tip = a.tip || "Please input the keywords",
				this.input = a.input,
				this.input) {
				if(this.form = a.form, !this.form && (b = this.input.parents("form")) && b.length && (this.form = b,
						b = null),
					this.submit = a.submit || this.submit,
					this.getDatas = a.getDatas || this.getDatas,
					this.suggest = a.suggest && a.suggest.length ? a.suggest : null, !this.suggest) {
					var c = this.input.parent(),
						d = document.createElement("div");
					c.css("position", "relative");
					var e = getPosition(this.input[0], c[0]).x,
						f = this.input.width(),
						g = getPosition(this.input[0], c[0]).y + this.input.height();
					d.style.cssText = "top:" + g + "px;left:" + e + "px;width:" + f + "px;",
						d.className = "suggest",
						c.append(d),
						this.suggest = jQuery(d)
				}
				this.suggest.hide(),
					this.list = (a.list || "li").toLowerCase(),
					this.hover = a.hover || "hover",
					this.input.attr("data-placeholder") || (this.input.val(this.tip),
						this.input.focus(jQuery.proxy(this.focus, this))),
					this.input.blur(jQuery.proxy(this.blur, this)),
					this.input.keydown(jQuery.proxy(this.keydown, this)),
					this.input.bind("keyup", jQuery.proxy(this.textInput, this)),
					this.form && this.form.bind("submit", jQuery.proxy(this.submit, this)),
					this.suggest.delegate(this.list, "mouseover", jQuery.proxy(this.mouseover, this)),
					this.suggest.delegate(this.list, "click", jQuery.proxy(this.click, this))
			}
		},
		focus: function() {
			this.input.val() == this.tip && this.input.val("")
		},
		blur: function() {
			var a = this;
			this.input.attr("data-placeholder") || "" != this.input.val() || this.input.val(this.tip),
				setTimeout(function() {
					a.suggest.hide(),
						a.current = null
				}, 500)
		},
		setInputValue: function(a) {
			var b, c = this.list;
			this.current || (this.current = this.suggest.find(c).first()),
				b = this.current.attr("title") || this.current.text(),
				this.input.val(b)
		},
		click: function() {
			this.setInputValue(),
				this.suggest.hide()
		},
		submit: function(a) {
			this.form && a.preventDefault()
		},
		keydown: function(a) {
			var b = a.keyCode,
				c = this.list,
				d = this.hover;
			if(38 == b || 40 == b) {
				if(!this.suggest.find(c).length)
					return;
				a.preventDefault(),
					this.current && this.current.removeClass(d),
					this.current = 38 == b ? this.current && this.current.prev().length ? this.current.prev() : this.suggest.find(c).last() : this.current && this.current.next().length ? this.current.next() : this.suggest.find(c).first(),
					this.current.addClass(d),
					this.setInputValue()
			} else
				13 == b && (this.setInputValue(),
					this.form || this.submit())
		},
		getDatas: function() {
			throw new Error('Method ".getDatas()" is needed.')
		},
		textInput: function(a) {
			var b = a.keyCode;
			(!b || b >= 48 && b <= 90 || b >= 96 && b <= 105 || 8 == b || 32 == b || 45 == b) && this.getDatas()
		},
		mouseover: function(a) {
			for(var b = a.target; b && b.nodeName.toLowerCase() != this.list;)
				b = b.parentNode;
			b.nodeName.toLowerCase() == this.list && (this.current && this.current.removeClass(this.hover),
				this.current = jQuery(b),
				this.current.addClass(this.hover))
		}
	});
! function(a, b, c) {
	a[b] = c()
}(this, "passport", function() {
	var $ = window.jQuery,
		util = window.Util,
		lid = window.LenovoId;
	if(window.sum = 0,
		window.getMobileCode = function(a) {
			"0" != a.ret && (tip.find("p").html(a.msg).end().show(),
				account.select())
		},
		window.doFastLogin = function(a) {
			if("0" == a.ret) {
				lid.lidlogin(a.tgt, $.trim(m_account.val()));
				var b = util.getDomain(passport.loginRedirect || document.URL),
					c = encodeURIComponent(a["cerpreg-passprt"]);
				/lenovo\.com\.cn|lenovouat\.cn/.test(b) ? (util.cookie.set("ar", "2"),
					loginAction(c)) : $.getScript("//reg." + b + "/auth/set_cookie?cookie=" + c + "&domain=" + b + "&ar=2", function() {
					loginAction(c)
				})
			} else
				clicktag = !1,
				tip.find("p").html(a.msg).end().show()
		},
		window.lVETEbVhueFZZkIHgsuausYSIksjdUYSHYjslkOISUhsSKUFDIUASDsaiISUAYSDs = function(a, b, c, d, e) {
			$.getScript("https://reg.lenovo.com.cn" + "/auth/v3/synlogin?tk=" + passport.ticket + "&ts=" + d + "&callback=fECS")
		},
		window.fECS = function(a) {
			var b = a.ret,
				c = util.getDomain(document.URL);
			if("0" == b) {
				var d = encodeURIComponent(a["cerpreg-passport"]);
				$.getScript("//reg." + c + "/auth/set_cookie?cookie=" + d + "&domain=" + c, function() {
					try {
						parseCookie(),
							passport.drawUserInfo()
					} catch(a) {}
					pullCookie(d)
				})
			}
		}, !$)
		throw new Error("未加载jQuery框架");
	var regAccount = /^(?:1[3456789]\d{9}|[a-z0-9-_\\.]+@([a-z0-9-]+[\\.]{1})+[a-z0-9-]+)$/i,
		needCaptcha = !1,
		loginType = 0,
		qrtoken = null,
		checkReady = !1,
		scanTimer = null,
		sliderFlag1 = !1,
		slider_codeid1 = "",
		slider_value1 = "",
		sliderfFlag1 = !1,
		slider_f_codeid1 = "",
		slider_f_value1 = "",
		clicktag = !1,
		pending = !1,
		error = function(a) {
			switch(a) {
				case 1:
					throw new Error("多次初始化,请避免");
				case 2:
					throw new Error("passport初始化少参数");
				case 3:
					throw new Error("WARNING:!!!shitJump，dangerous!!!");
				case 4:
					throw new Error("非法请求")
			}
		},
		drawMask = function() {
			$("#ppMask").length || $("body").append('<div id="ppMask" class="ppMask"></div>')
		},
		parseCookie = function() {
			if(!passport.cookie) {
				var a = unescape(util.cookie.get("cerpreg-passport"));
				if(a) {
					var b = a.split("|"),
						c = b[4];
					if(b && c) {
						var d = decodeURIComponent(unescape(Base64.decode(c))),
							e = d.split("|");
						passport.cookie = {};
						for(var f = 0; f < e.length; f++) {
							var g = e[f].split(":"),
								h = g[0],
								i = g[2];
							passport.cookie[h] = i
						}
					}
				}
			}
		},
		drawDefaultLoginForm = function() {
			var a = passport.ticket,
				b = encodeURIComponent(document.URL),
				c = [];
			c.push('<div class="ppWrapper" id="ppWrapper">'),
				c.push('<a class="close" href="javascript:void(0)" latag="latag_pc_login_boxclose"></a>'),
				c.push('<div class="login_pp">'),
				c.push('<div class="login_title">联想会员登录</div>'),
				c.push('<div id="normal_login_box" class="login-content"> <div class="login_input login_inputa"><input type="text" data-placeholder="邮箱/手机号码" class="input account"><i class="icon-clear icon-account"></i></div><div class="login_input login_inputb"><input id="pwd" type="password" data-placeholder="密码" class="input pwd"></div><div id="slider_dialog" class="slider"></div></div>'),
				c.push('<div id="fast_login_box" class="login-content"><div class="login_input login_inputc"><input type="text" data-placeholder="输入手机号码" class="input account_f"><i class="icon-clear icon-fast"></i></div><div id="slider_f_dialog" class="slider"></div> <div class="login_input clearfix login_inputd"><input type="text" class="captcha" data-placeholder="短信验证码"><a href="javascript:;" class="captcha_btn getMobileCode" latag="latag_pc_login_getMobileCode">获取验证码</a></div></div>'),
				c.push('<div class="error-container"><i class="icon-error"></i><p class="error-msg">用户名不正确</p></div><div class="login_mains"> <input class="persistent" checked="" type="checkbox" latag="latag_pc_login_autologin" id="psAuto"> <label for="psAuto">自动登录</label></div>'),
				c.push('<a href="javascript:void(0)" latag="latag_pc_login_confirm" class="submit">登录</a><div class="login_mains clearfix"><a href="javascript:;" class="login_type login_fast" latag="latag_pc_login_quick" type="1">手机验证码快捷登录</a><a href="javascript:;" class="login_type login_account" latag="latag_pc_login_normal" type="0">用户名密码登录</a><div class="login_others"><a href="javascript:;" class="regist_btn" latag="latag_pc_login_register">立即注册</a><a href="javascript:;" class="reset_btn" latag="latag_pc_login_forgetpw">忘记密码？</a></div></div>'),
				c.push('<div class="cooperation"><div class="cooperation-title"><span></span> <em>其他登录方式</em><span></span></div><div class="cooperation_items clearfix"><a href="https://' + "reg.lenovo.com.cn" + "/auth/qqplat?ru=" + b + "&tk=" + a + '" latag="latag_pc_login_qq" class="qq"><i class="icon-type icon-qq"></i></a><a href="https://' + "reg.lenovo.com.cn" + "/auth/sinaplat?ru=" + b + "&tk=" + a + '" latag="latag_pc_login_weibo" class="wb"><i class="icon-type icon-wb"></i></a><a href="https://reg.lenovo.com.cn/auth/wechatcode?ru=' + b + "&tk=" + a + '" latag="latag_pc_login_weixin" class="wx"><i class="icon-type icon-wx"></i></a><a href="https://' + "reg.lenovo.com.cn" + "/auth/alipayplat?ru=" + b + "&tk=" + a + '" latag="latag_pc_login_zhifubao" class="zfb"><i class="icon-type icon-zfb"></i></a></div></div>'),
				c.push("</div>"),
				c.push('<div class="login_scan">'),
				c.push('<div class="login_title"><div class="login_title">联想会员扫码登录</div></div>'),
				c.push('<div class="qrcode_mod"> <div class="qrcode_desc"><p>打开<em>微信</em>扫码登录</p></div><div class="qrcode_main"><div class="qrcode_info"><img class="qrcode_img"></div><div class="qrcode_success"><img src="//m2.lefile.cn/lenovo_passport/1.4.20/img/HomePageImg/scan_succ.gif"><h3>扫描成功!</h3><p>请勿刷新本页面，按手机提示操作！</p></div><div class="qrcode_error"><h6>二维码已失效</h6><a href="javascript:void(0)" class="qrcode_refresh">刷新</a></div></div></div>'),
				c.push("</div>"),
				c.push('<div class="login_hd">'),
				c.push('<div class="login_switch"><p class="login_scan_tip"></p><p class="login_pp_tip"></p></div>'),
				c.push('<div class="login_tip"><div class="poptip"><div class="poptip_arrow"><em></em><span></span></div><div class="poptip_content"><i><img src="//m1.lefile.cn/lenovo_passport/1.4.20/img/HomePageImg/icon-prevent.png" alt=""></i>扫码登录更安全</div></div></div>'),
				c.push("</div>"),
				c.push("</div>"),
				$("body").append(c.join("")),
				passport.rootElement = $("#ppWrapper")
		};
	window.getMobile = function(a) {
		var b = $(".getMobileCode", passport.rootElement);
		if("0" == a.ret)
			var c = 60,
				d = setInterval(function() {
					0 == c ? (clearInterval(d),
						pending = !1,
						b.html("获取验证码"),
						slider_dialog_2.reset(),
						sliderfFlag1 = !1) : (b.html("已发送" + c),
						c--)
				}, 1e3);
		else
			tip.find("p").html(a.msg).end().show(),
			pending = !1,
			slider_dialog_2.reset(),
			sliderfFlag1 = !1
	};
	var flRequest = function(a) {
			var b = Math.random() + "",
				c = 1e13 * b;
			$("body").append('<iframe src="https://6895322.fls.doubleclick.net/activityi;src=6895322;type=lenov0;cat=crm_l0;u1=' + a + ";dc_lat=;dc_rdid=;tag_for_child_directed_treatment=;ord=1;num=" + c + '?" width="1" height="1" frameborder="0" style="display:none"></iframe>')
		},
		account, m_account, pwd, mcode, submit, tip, code_btn, slider_dialog_1, slider_dialog_2, reset = function() {
			account.removeClass("error_bg").val(""),
				m_account.removeClass("error_bg").val(""),
				mcode.removeClass("error_bg").val(""),
				pwd.removeClass("error_bg").val(""),
				slider_dialog_2.reset(),
				sliderfFlag1 = !1,
				needCaptcha && (slider_dialog_1.reset(),
					sliderFlag1 = !1),
				code_btn.val("获取验证码"),
				pending = !1,
				clicktag = !1,
				$(".icon-clear").removeClass("icon-err-delete").hide(),
				$(".error-container").find("p").html("").end().hide()
		},
		bindLoginEvents = function() {
			account = passport.rootElement.find(".account"),
				m_account = passport.rootElement.find(".account_f"),
				pwd = passport.rootElement.find(".pwd"),
				mcode = passport.rootElement.find(".captcha"),
				code_btn = passport.rootElement.find(".getMobileCode"),
				tip = passport.rootElement.find(".error-container"),
				submit = passport.rootElement.find(".submit"),
				window.attachEvent ? $("input").on("keydown", function() {
					$("input").removeClass("error_bg").parent(".login_input").find("i").removeClass("icon-err-delete"),
						$(".error-container").find("p").html("").end().hide(),
						$(this).val() ? ($(this).parent(".login_input").find(".icon-clear").removeClass("icon-err-delete").show(),
							$(this).addClass("input")) : ($(this).parent(".login_input").find(".icon-clear").removeClass("icon-err-delete").hide(),
							$(this).removeClass("input"))
				}).on("focus", function() {
					$(this).addClass("focusIn")
				}).on("blur", function() {
					$(this).removeClass("focusIn")
				}) : $("input").on("input", function() {
					$("input").removeClass("error_bg").parent(".login_input").find("i").removeClass("icon-err-delete"),
						$(".error-container").find("p").html("").end().hide(),
						$(this).val() ? ($(this).parent(".login_input").find(".icon-clear").removeClass("icon-err-delete").show(),
							$(this).addClass("input")) : ($(this).parent(".login_input").find(".icon-clear").removeClass("icon-err-delete").hide(),
							$(this).removeClass("input"))
				}).on("focus", function() {
					$(this).addClass("focusIn")
				}).on("blur", function() {
					$(this).removeClass("focusIn")
				}),
				$(".icon-clear").on("click", function() {
					$(this).parent().find("input").val("").removeClass("input error_bg").focus().end().end().hide()
				}),
				passport.rootElement.delegate(".login_type", "click", function() {
					var a = $(this).attr("type");
					loginType = a,
						"0" == a ? ($("#normal_login_box,.login_fast").show(),
							$("#fast_login_box,.login_account").hide(),
							reset(),
							$(".m_account_placeholder,.mcode_placeholder").hide(),
							$(".account_placeholder,.pwd_placeholder").show()) : "1" == a && ($("#fast_login_box,.login_account").show(),
							$("#normal_login_box,.login_fast").hide(),
							reset(),
							$(".account_placeholder,.pwd_placeholder").hide(),
							$(".mcode_placeholder").length || (util.simulatePlaceholder(m_account, "m_account_placeholder", $(".login_inputc", passport.rootElement)),
								util.simulatePlaceholder(mcode, "mcode_placeholder", $(".login_inputd", passport.rootElement))),
							$(".m_account_placeholder,.mcode_placeholder").show())
				}).delegate(".login_scan_tip", "click", function() {
					$(".qrcode_error").attr("isShow") && $(".qrcode_error").hide(),
						$(".qrcode_success").attr("isShow") && ($(".qrcode_success").removeAttr("isShow").hide(),
							$(".qrcode_info,.qrcode_desc").show()),
						$(".login_pp,.login_scan_tip,.login_tip").hide(),
						$(".login_scan,.login_pp_tip").show(),
						qrcodeRefresh()
				}).delegate(".login_pp_tip", "click", function() {
					$(".login_scan,.login_pp_tip").hide(),
						$(".login_pp,.login_scan_tip,.login_tip").show(),
						checkReady = !1,
						clearInterval(scanTimer)
				}).delegate(".qrcode_refresh", "click", function() {
					$(".qrcode_error").removeAttr("isShow").hide(),
						qrcodeRefresh()
				}).delegate(".getMobileCode", "click", function() {
					var a = $.trim(m_account.val());
					$(this);
					return !pending && (/^\s*$/.test(a) ? (tip.find("p").html("手机号码不能为空").end().show(),
						m_account.addClass("error_bg").focus(),
						slider_dialog_2.reset(),
						void(sliderfFlag1 = !1)) : /^1[3-9]\d{9}$/.test(a) ? sliderfFlag1 ? (pending = !0,
						void $.getScript("//" + "reg.lenovo.com.cn" + "/captcha/cansend?mobile=" + a + "&codeid=" + slider_f_codeid1 + "&code=" + slider_f_value1 + "&callback=getMobile")) : (slider_dialog_2.reset(),
						sliderfFlag1 = !1,
						void tip.find("p").html("滑块验证失败，请重试").end().show()) : (tip.find("p").html("手机号码格式不正确").end().show(),
						m_account.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete"),
						slider_dialog_2.reset(),
						void(sliderfFlag1 = !1)))
				}).delegate(".m_account", "blur", function(a) {
					var b = (a.keyCode,
						$.trim($(this).val()));
					/^\s*$/.test(b) ? tip.find("p").html("手机号码不能为空").end().show() : /^1[3-9]\d{9}$/.test(b) || tip.find("p").html("手机号码格式不正确").end().show()
				}).delegate(".pwd,.captcha", "keydown", function(a) {
					13 == a.keyCode && (a.preventDefault(),
						passport.doLogin())
				}).delegate(".submit", "click", function(a) {
					a.preventDefault(),
						passport.doLogin()
				}).delegate(".close", "click", function(a) {
					passport.hide(),
						needCaptcha = !1,
						clearInterval(scanTimer)
				}).delegate(".regist_btn", "click", function() {
					window.open("https://" + "reg.lenovo.com.cn" + "/auth/v1/regist?ru=" + location.href + "&ticket=" + passport.ticket)
				}).delegate(".reset_btn", "click", function() {
					window.open("https://" + "reg.lenovo.com.cn" + "/pwd/findpwd?ru=" + location.href + "&ticket=" + passport.ticket)
				}),
				window.gapop || (! function(a, b, c, d, e, f, g) {
						a.GoogleAnalyticsObject = e,
							a[e] = a[e] || function() {
								(a[e].q = a[e].q || []).push(arguments)
							},
							a[e].l = 1 * new Date,
							f = b.createElement(c),
							g = b.getElementsByTagName(c)[0],
							f.async = 1,
							f.src = d,
							g.parentNode.insertBefore(f, g)
					}(window, document, "script", "https://www.google-analytics.com/analytics.js", "gapop"),
					gapop("create", "UA-110299082-1", "auto", {
						userId: ""
					}),
					gapop("require", "ec"),
					gapop(function(a) {
						var b = a.get("clientId");
						gapop("set", "dimension1", b)
					}),
					gapop("set", "dimension2", "")),
				$("body").on("click", ".login_mains.clearfix .regist_btn", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_立即注册")
				}),
				$("body").on("click", ".login_mains.clearfix .reset_btn", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_忘记密码")
				}),
				$("body").on("click", ".login_mains.clearfix .login_type.login_fast", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_手机验证码快捷登录")
				}),
				$("body").on("click", ".login_mains.clearfix .login_type.login_account", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_用户名密码登录")
				}),
				$("body").on("click", ".cooperation_items.clearfix .qq", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_QQ登录")
				}),
				$("body").on("click", ".cooperation_items.clearfix .wb", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_Sina登录")
				}),
				$("body").on("click", ".cooperation_items.clearfix .wx", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_Wechat登录")
				}),
				$("body").on("click", ".cooperation_items.clearfix .zfb", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_Alipay登录")
				}),
				$("body").on("click", "div.account_placeholder", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_账户")
				}),
				$("body").on("click", "div.m_account_placeholder", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_手机号")
				}),
				$("body").on("click", "div.mcode_placeholder", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_手机验证码")
				}),
				$("body").on("click", "div.pwd_placeholder", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_密码")
				}),
				$("body").on("click", ".getMobileCode", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_获取验证码")
				}),
				$("body").on("click", "#psAuto", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_自动登录")
				}),
				$("body").on("click", ".submit", function() {
					gapop("send", "event", "Lenovo_PC", "Lenovo_会员登录", "Click_登录"),
						_doSubmit()
				})
		},
		qrcodeRefresh = function() {
			-1 != location.host.indexOf("thinkpad.com") ? $(".qrcode_img").attr("src", "//reg.thinkpad.com/auth/qrcodelogin/show?" + (new Date).getTime()) : $(".qrcode_img").attr("src", "//" + "reg.lenovo.com.cn" + "/auth/qrcodelogin/show?" + (new Date).getTime()),
				$(".qrcode_img")[0].onload = function() {
					checkReady = !0,
						(qrtoken = util.cookie.get("qrtoken")) && (scanTimer = setInterval(function() {
							checkReady && queryScan()
						}, 3e3))
				}
		},
		queryScan = function() {
			var _domain = location.host,
				domain = "";
			domain = -1 != _domain.indexOf("thinkpad.com") ? "reg.thinkpad.com" : "reg.lenovo.com.cn",
				$.ajax({
					url: "//" + domain + "/auth/qrcodelogin/qrcodeLoginCheck/" + qrtoken,
					type: "GET",
					dataType: "jsonp",
					jsonp: "callback",
					jsonpCallback: "jQuery" + (new Date).getTime(),
					success: function(o) {
						if("string" == typeof o && (o = eval("(" + o + ")")),
							"3" == o.status)
							clearInterval(scanTimer),
							checkReady = !1,
							$(".qrcode_info,.qrcode_desc").show(),
							$(".qrcode_success").hide(),
							$(".qrcode_error").find("h6").html("二维码已失效").end().attr("isShow", "1").show();
						else if("2" == o.status)
							$(".qrcode_info,.qrcode_desc").hide(),
							$(".qrcode_success").attr("isShow", "1").show();
						else if("4" == o.status) {
							clearInterval(scanTimer);
							var cp = encodeURIComponent(o["cerpreg-passport"]),
								tgt = o.tgt;
							loginAction(cp, tgt)
						} else
							"5" == o.status && (clearInterval(scanTimer),
								checkReady = !1,
								$(".qrcode_info,.qrcode_desc").show(),
								$(".qrcode_success").hide(),
								$(".qrcode_error").find("h6").html("登录失败").end().attr("isShow", "1").show())
					}
				})
		},
		ucInit = function(a, b) {
			var c = new worker;
			return c.init({
					renderTo: "#" + a,
					success: function(b) {
						"slider_dialog" == a ? (sliderFlag1 = !0,
							slider_codeid1 = b.codeid,
							slider_value1 = b.value) : (sliderfFlag1 = !0,
							slider_f_codeid1 = b.codeid,
							slider_f_value1 = b.value)
					},
					error: function(b) {
						"slider_dialog" == a ? (sliderFlag1 = !1,
							slider_codeid1 = "",
							slider_value1 = "",
							slider_dialog_1.reset()) : (sliderfFlag1 = !1,
							slider_f_codeid1 = "",
							slider_f_value1 = "",
							slider_dialog_2.reset())
					},
					btnCancel: "." + b,
					errorMsg: "哎呀，出错了，点击<a href='javascript://;' class='" + b + "'>刷新</a>",
					width: 330,
					height: 46,
					sliderBg: "rgba(255,255,255,0)",
					color: "#424242",
					fontSize: 14,
					bgColor: "#33CC00",
					successMsg: "验证成功",
					successColor: "#fff",
					errorFontSize: 14,
					errorColor: "blue",
					errorBgColor: "rgba(255,255,255,0)"
				}),
				c
		},
		standardLogin = function() {
			var a, b = passport.rootElement.find(".persistent"),
				c = $.trim(account.val()),
				d = pwd.val();
			if(a = b.length ? b[0].checked ? "1" : "0" : 1,
				/^\s+$/.test(c))
				return tip.find("p").html("账号不能为空").end().show(),
					clicktag = !1,
					slider_dialog_1.reset(),
					sliderFlag1 = !1,
					void account.addClass("error_bg").focus();
			if(!regAccount.test(c))
				return tip.find("p").html("用户名不正确").end().show(),
					clicktag = !1,
					slider_dialog_1.reset(),
					sliderFlag1 = !1,
					void account.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete");
			if(/^\s*$/.test(d))
				return tip.find("p").html("密码不能为空").end().show(),
					clicktag = !1,
					slider_dialog_1.reset(),
					sliderFlag1 = !1,
					void pwd.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete");
			if(d.length < 4)
				return tip.find("p").html("用户名或者密码不正确").end().show(),
					clicktag = !1,
					slider_dialog_1.reset(),
					sliderFlag1 = !1,
					void pwd.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete");
			if(needCaptcha && !sliderFlag1)
				return clicktag = !1,
					slider_dialog_1.reset(),
					sliderFlag1 = !1,
					void tip.find("p").html("滑块验证失败，请重试").end().show();
			var e = {
					account: c,
					password: d,
					ps: a,
					ticket: passport.ticket,
					codeid: slider_codeid1,
					code: slider_value1
				},
				f = passport.options || {};
			$.each(f, function(a, b) {
					e[a] = b
				}),
				submit.html("正在登录，请稍候... ..."),
				util.simulateFormSubmit("https://reg.lenovo.com.cn" + "/auth/v3/dologin", e, function(a) {
					var b = a.ret,
						c = util.getDomain(passport.loginRedirect || document.URL);
					if(submit.html("登录"),
						clicktag = !1,
						"0" == b) {
						lid.lidlogin(a.tgt, $.trim(account.val()));
						var d = encodeURIComponent(a["cerpreg-passport"]);
						/lenovo\.com\.cn|lenovouat\.cn/.test(c) ? (util.cookie.set("ar", "2", null, "." + c),
							loginAction(d)) : $.getScript("//reg." + c + "/auth/set_cookie?cookie=" + d + "&domain=" + c + "&ar=2", function() {
							loginAction(d)
						})
					} else {
						if(tip.find("p").html(a.msg).end().show(),
							pwd.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete"),
							needCaptcha)
							return $("#slider_dialog").show(),
								slider_dialog_1.reset(),
								void(sliderFlag1 = !1);
						"false" == a.isshowpic && (needCaptcha = !0,
							$("#slider_dialog").show(),
							slider_dialog_1.reset(),
							sliderFlag1 = !1)
					}
				}, function() {
					clicktag = !1,
						account.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete"),
						submit.html("登录超时，请稍后重试"),
						slider_dialog_1.reset(),
						sliderFlag1 = !1
				})
		},
		quickLogin = function() {
			var a, b = passport.rootElement.find(".persistent"),
				c = $.trim(m_account.val()),
				d = $.trim(mcode.val());
			return a = b.length ? b[0].checked ? "1" : "0" : 1,
				/^\s+$/.test(c) ? (tip.find("p").html("手机号码不能为空").end().show(),
					m_account.addClass("error_bg").focus(),
					void(clicktag = !1)) : /^1[3-9]\d{9}$/.test(c) ? /^\s*$/.test(d) ? (tip.find("p").html("验证码不能为空").end().show(),
					mcode.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete"),
					void(clicktag = !1)) : void $.getScript("https://reg.lenovo.com.cn" + "/auth/v1/fastlogin?ticket=" + passport.ticket + "&account=" + c + "&captcha=" + d + "&ps=" + a + "&callback=doFastLogin", function() {}) : (tip.find("p").html("手机号码格式不正确").end().show(),
					m_account.addClass("error_bg").focus().parent().find(".icon-clear").addClass("icon-err-delete"),
					void(clicktag = !1))
		},
		loginAction = function(a, b) {
			var c;
			(c = passport.loginRedirect) ? location.href = util.absolutizeURI(location.href, c): ($(".ppWrapper").remove(),
				$(".ppMask").hide(),
				loginType = 0,
				parseCookie(),
				b && lid.lidlogin(b, passport.cookie.loginName),
				flRequest(passport.cookie.lenovoId),
				passport.drawUserInfo && passport.drawUserInfo(),
				passport.login && passport.login(),
				passport.callbacks.fire(),
				pullCookie(a))
		},
		isShitJump = function() {
			var a = passport.login && passport.login.toString(),
				b = passport.logout && passport.logout.toString(),
				c = passport.drawUserInfo && passport.drawUserInfo.toString(),
				d = /location\.href|reload\(/;
			return d.test(a) || d.test(b) || d.test(c)
		},
		pullCookie = function(a) {
			var b = "thinkpad.com,lenovo.cn".split(","),
				c = (location.protocol,
					"" == a ? "clear_cookie?" : "set_cookie?cookie=" + a + "&");
			$.each(b, function(a, b) {
				b != document.domain && ((new Image).src = "thinkworld.com.cn" == b ? "http://reg." + b + "/auth/" + c + "domain=" + b : "//reg." + b + "/auth/" + c + "domain=" + b)
			})
		},
		createLeID = function() {
			var a = util.cookie.get("leid") || "",
				b = "1.";
			if(0 != a.indexOf(b)) {
				var c = document.createElement("iframe");
				c.style.cssText = "display:none",
					c.src = "//" + "reg.lenovo.com.cn" + "/auth/anonymous",
					$("body").append(c)
			}
		},
		passport = {
			ticket: null,
			cookie: null,
			options: null,
			loginRedirect: null,
			logoutRedirect: null,
			rootElement: null,
			drawLoginForm: null,
			drawUserInfo: null,
			login: null,
			logout: null,
			cssUrl: null,
			callbacks: $.Callbacks(),
			callbacks1: $.Callbacks(),
			addLoginCallback: function(a) {
				a && passport.callbacks.add(a)
			},
			addLogoutCallback: function(a) {
				a && passport.callbacks1.add(a)
			},
			isLogin: function() {
				return parseCookie(), !(!this.cookie || "" == this.cookie.lenovoId) || (util.cookie.get("sce") || (util.cookie.set("sce", "1"),
					$.getScript("//passport.lenovo.com/wauthen2/synCookie.jhtml?lenovoid_realm=shop.lenovo.com.cn", function() {
						util.cookie.remove("sce")
					})), !1)
			},
			show: function() {
				var a = function() {
					regAccount = /^(?:1[3456789]\d{9}|[a-z0-9-_\\.]+@([a-z0-9-]+[\\.]{1})+[a-z0-9-]+)$/i,
						needCaptcha = !1,
						$("#ppMask").show(),
						passport.rootElement.show(),
						$(".login_pp_tip", passport.rootElement).trigger("click"),
						$(".qrcode_success", passport.rootElement).hide(),
						$(".qrcode_info", passport.rootElement).show(),
						$(".qrcode_desc", passport.rootElement).show(),
						$(".login_type[type=0]", passport.rootElement).trigger("click"),
						$(".account_placeholder").length || (util.simulatePlaceholder(account, "account_placeholder", $(".login_inputa", passport.rootElement)),
							util.simulatePlaceholder(pwd, "pwd_placeholder", $(".login_inputb", passport.rootElement))),
						$(".account_placeholder,.pwd_placeholder").show()
				};
				passport.rootElement && (a(),
					window.gapop && (gapop("set", "page", "/pop-up/login"),
						gapop("send", "pageview")));
				var b = setInterval(function() {
					passport.rootElement && (clearInterval(b),
						a())
				}, 50)
			},
			hide: function() {
				account.val(""),
					m_account.val(""),
					pwd.val(""),
					mcode.val(""),
					tip.find("p").html("").end().hide(),
					loginType = 0,
					slider_dialog_1.reset(),
					slider_dialog_2.reset(),
					$("#ppMask").hide(),
					passport.rootElement.hide()
			},
			init: function(a) {
				if(passport.ticket)
					return void error(1);
				$(function() {
					var b = a.ticket,
						c = a.drawUserInfo;
					if(!b)
						return void error(2);
					if(passport.ticket = b,
						passport.loginRedirect = a.loginRedirect || passport.loginRedirect || null,
						passport.logoutRedirect = a.logoutRedirect || passport.logoutRedirect || null,
						passport.drawUserInfo = c || null,
						passport.login = a.login || null,
						passport.logout = a.logout || null,
						passport.cssUrl = a.cssUrl || null,
						isShitJump())
						return void error(3);
					if(passport.options = a.options,
						drawMask(),
						passport.isLogin())
						c && passport.drawUserInfo();
					else {
						var d = a.drawLoginForm;
						util.loadCSS(passport.cssUrl || "//m2.lefile.cn/lenovo_passport/1.4.20/css/pr.min.css", function() {
							if(d) {
								var b = a.rootElement;
								if(!b)
									return void error(2);
								passport.rootElement = b,
									passport.drawLoginForm = d,
									d()
							} else
								drawDefaultLoginForm();
							window.worker && "function" == typeof worker && (slider_dialog_1 = ucInit("slider_dialog", "btnCancle_dialog1"),
									slider_dialog_2 = ucInit("slider_f_dialog", "btnCancle_dialog2")),
								bindLoginEvents()
						})
					}
				})
			},
			doLogin: function() {
				if(clicktag)
					return !1;
				clicktag = !0,
					"0" == loginType ? standardLogin() : quickLogin()
			},
			doLogout: function() {
				var a = util.getDomain(passport.logoutRedirect || document.URL),
					b = location.protocol || "http:";
				lid.lidlogout(passport.cookie.loginName),
					$.getScript(b + "//reg." + a + "/auth/clear_cookie?domain=" + a + "&ar=2", function() {
						if(passport.logoutRedirect) {
							var c = passport.logoutRedirect;
							location.href = util.absolutizeURI(location.href, c)
						} else
							util.loadCSS(passport.cssUrl || "//m1.lefile.cn/lenovo_passport/1.4.20/css/pr.min.css", function() {
								passport.cookie = !1,
									passport.drawLoginForm ? passport.drawLoginForm() : drawDefaultLoginForm(),
									window.worker && "function" == typeof worker && (slider_dialog_1 = ucInit("slider_dialog", "btnCancle_dialog1"),
										slider_dialog_2 = ucInit("slider_f_dialog", "btnCancle_dialog2")),
									passport.rootElement.hide(),
									bindLoginEvents(),
									passport.logout && passport.logout(),
									passport.callbacks1.fire(),
									pullCookie(""),
									"lenovo.com.cn" != a && ((new Image).src = b + "//reg.lenovo.com.cn/auth/clear_cookie?domain=lenovo.com.cn")
							})
					})
			},
			load: function(a) {
				a && a()
			},
			sync: function(a, b, c, d, e, f) {
				$.ajax({
					url: "//reg.lenovo.com.cn/auth/synck/dologin",
					dataType: "jsonp",
					data: {
						ts: a,
						tk: b,
						rm: c
					},
					success: function(a, b) {
						if(0 != a.ret)
							d && d(a, b);
						else {
							var c = a["cerp-passport"];
							util.cookie.set("cerp-passport", c),
								e && e(a, b),
								pullCookie(c)
						}
					},
					error: function(a, b, c) {
						f && f(b, c)
					}
				})
			}
		},
		referrer = document.URL;
	if(util.cookie.get("ar") && /[^\?&]+(lenovo(?:vip|uat)?|thinkworldshop|thinkworld)\./.test(referrer)) {
		var cookie = util.cookie.get("cerpreg-passport") || "";
		pullCookie(encodeURIComponent(cookie)),
			util.cookie.remove("ar", util.getDomain(document.URL))
	}
	return setTimeout(function() {
			createLeID()
		}, 1e3),
		$(function() {
			util.loadJS("//" + "reg.lenovo.com.cn" + "/mt/cc?" + (new Date).getTime())
		}),
		passport.loginAction = loginAction,
		passport.pullCookie = pullCookie,
		passport
}),
function(a) {
	var b = Util,
		c = LenovoId;
	a(function() {
		var d = (document.body.scrollWidth,
			document.body.scrollHeight);
		0 == d && (d = document.documentElement.scrollHeight);
		var e, f, g, h, i, j, k, l, m, n, o, p, q, r, s = "//" + "reg.lenovo.com.cn",
			t = /^(?:1[34578]\d{9}|[a-z0-9-_\\.]+@([a-z0-9-]+[\\.]{1})+[a-z0-9-]+)$/i,
			u = /(?!^(\d+|[a-zA-Z]+|[~!@#$%^&*?\.>\-\=\+<\(\),\[\];:\/]+)$)^[\w~!@#$%^&*?\.>\-\=\+<\(\),\[\];:\/]{8,20}$/,
			v = function() {
				h.hide(),
					g.hide(),
					a(".rr_account_placeholder").length && (a(".rr_account_placeholder").remove(),
						a(".rr_pwd_placeholder").remove())
			},
			w = '<div class="enroll" style="height: 420px;"> <div class="enroll_title"> <h1>欢迎注册联想会员</h1> <a class="close" href="javascript:void(0)" latag="latag_pc_register_boxclose" style="text-decoration:none;"></a></div> <div class="enroll_inputa"> <p><label>账号</label><input class="account" type="text" data-placeholder="请输入手机号"></p> </div> <div class="enroll_inputaa errorAccount"></div> <div class="enroll_inputb"> <p><label>密码</label><input data-placeholder="密码长度8~20位,数字、字母、字符至少包含两种" class="pwd" type="password"/></p> </div> <div class="enroll_inputaa errorPwd"></div> <div class="enroll_inputc"> <p><label>确认密码</label><input type="password" class="repwd"></p> </div> <div class="enroll_inputaa errorRepwd"></div> <div class="enroll_inputd"> <p><label>验证码</label><input type="text" class="captcha_code"></p><img class="img_captcha" style="width: 120px;height:28px" latag="latag_pc_register_verificationcode"><span class="img_captcha_tip" latag="latag_pc_register_verificationcode">换一张</span></div><div class="enroll_inputaa errorCaptcha_code"></div><div class="enroll_inputd"> <p><label>手机验证码</label><input type="text" class="captcha"></p><button class="mobile_captcha" style="margin-left:3px;">获取手机验证码</button></div> <div class="enroll_inputaa errorCaptcha"></div> <div class="enroll_main"><label> <input type="checkbox" class="chk" checked><p style="color: #000"> 同意联想的 <a target="_blank" href="http://appserver.lenovo.com.cn/Public/public_bottom/legal.shtml" style="color: #005ce6;" latag="latag_pc_register_privacy">使用条款</a> 和 <a target="_blank" href="http://appserver.lenovo.com.cn/Public/public_bottom/privacy.shtml" style="color: #005ce6;" latag="latag_pc_register_privacy">隐私权政策</a> </p></label> </div> <div class="enroll_btn"> <a  style="text-decoration:none;" class="submit" href="javascript:void(0)" latag="latag_pc_register_confirm">立即注册</a> </div> </div>',
			x = '<div class="password_one" style="left:0;top:0;background:#fff"> <div class="password_titles"> <p><span>找回密码</span>&nbsp;&nbsp;&gt;&gt;第一步</p>  <a class="close" href="javascript:void(0)"></a></div> <div class="password_inputa"> <p>账号：<input class="account" type="text" data-placeholder="请输入手机号或邮箱"></p> </div> <div class="enroll_inputaa errorAccount recoverError"> </div> <div class="password_inputb"><p>验证码：<input class="captcha_code" type="text" data-placeholder="请输入验证码"></p><img class="img_captcha" style="width: 120px;height:28px" /><span class="img_captcha_tip">换一张</span></div> <div class="enroll_inputaa errorCaptcha_code recoverError"> </div> <div class="password_inputc" style="display: none;"> <p>手机验证码：<input class="captcha" type="text"></p><button class="mobile_captcha">获取手机验证码</button></div> <div class="enroll_inputaa errorCaptcha recoverError" style="display: none;"> </div>    <div class="password_inputd" style="display: none;"><p>新密码：<input class="pwd" type="password" data-placeholder="密码长度8~20位,数字、字母、字符至少包含两种"></p></div><div class="enroll_inputaa errorPwd recoverError" style="display: none;"> </div><div class="password_inpute" style="display: none;"><p>确认新密码：<input class="repwd" type="password"></p></div><div class="enroll_inputaa errorRepwd recoverError" style="display: none;"> </div> <div class="password_btns"> <a href="javascript:void(0)" class="submit">下一步</a> </div> </div><div class="password_two" style="left:0;top:0;background:#fff;display: none;"> <div class="password_title"> <p><span>找回密码</span>&nbsp;&nbsp;&gt;&gt;第二步</p> <a class="close" href="javascript:void(0)"></a></div> <div class="password_cont"> <img src="//m1.lefile.cn/lenovo_passport/1.4.20/img/HomePageImg/icon01.png"> <h1></h1> </div> <div class="password_btn"> <a href="javascript:void(0)">进入邮箱</a> </div> <div class="password_main"> <p>请您注意接收信息，并按照信息中的提示操作，完成安全验证。</p> </div> </div>',
			y = {
				error: function(b) {
					switch(b) {
						case "0":
							a(".errorAccount").html('<p class="error">请输入正确格式的账号</p>');
							break;
						case "1":
							a(".errorPwd").html('<p class="error">密码长度8-20位</p>');
							break;
						case "2":
							a(".errorPwd").html('<p class="error">密码至少包含数字、字母、字符其中的2种</p>');
							break;
						case "3":
							a(".errorRepwd").html('<p class="error">确认密码和密码不一致，请重新输入</p>');
							break;
						case "4":
							a(".errorCaptcha").html('<p class="error">输入的验证码不对，请重新输入</p>');
							break;
						case "5":
							a(".errorCaptcha").html('<p class="error">输入的验证码过期，请重新获取</p>');
							break;
						case "6":
							a(".errorAccount").html('<p class="error">账号已存在</p>');
							break;
						case "7":
							a(".errorAccount").html('<p class="error">账号不存在</p>');
							break;
						case "8":
							a(".errorAccount").html('<p class="error">账号不能为空</p>');
							break;
						case "9":
							a(".errorCaptcha").html('<p class="error">验证码不能为空</p>');
							break;
						case "10":
							a(".errorPwd").html('<p class="error">密码不能为空</p>');
							break;
						case "11":
							a(".errorAccount").html('<p class="error">正在校验账号...</p>');
							break;
						case "12":
							a(".errorCaptcha_code").html('<p class="error">验证码格式错误</p>');
							break;
						case "13":
							a(".errorCaptcha_code").html('<p class="error">验证码不能为空</p>');
							break;
						case "14":
							a(".errorCaptcha").html('<p class="error">手机验证码不能为空</p>')
					}
				},
				account: function(b) {
					var c = i.val();
					return i.cacheVal != c && (i.cacheVal = c,
						/^\s*$/.test(c) ? y.error("8") : "recover" != b || t.test(c) ? b && "recover" != b && !/^(?:1[34578]\d{9})$/i.test(c) ? y.error("0") : ("recover" == b ? (a.getScript(s + "/auth/validateAccount?account=" + c + "&callback=response.authAccountRecover"),
								/^(?:1[34578]\d{9})$/i.test(c) ? (a(".password_inputc,.errorCaptcha").show(),
									a(".password_inputd,.errorPwd").show(),
									a(".password_inpute,.errorRepwd").show()) : (a(".password_inputc,.errorCaptcha").hide(),
									a(".password_inputd,.errorPwd").hide(),
									a(".password_inpute,.errorRepwd").hide())) : a.getScript(s + "/auth/validateAccount?account=" + c + "&callback=response.authAccount"),
							void y.error("11")) : y.error("0"))
				},
				pwd: function() {
					var b = j.val();
					return /^\s*$/.test(b) ? void y.error("10") : b.length < 8 || b.length > 20 ? void y.error("1") : u.test(b) ? (a(".errorRepwd").html(""),
						void a(".errorPwd").html("")) : void y.error("2")
				},
				repwd: function() {
					if(k.val() != j.val())
						return void y.error("3");
					a(".errorRepwd").html("")
				},
				captcha_code: function() {
					var b = l.val();
					return /^\s*$/.test(b) ? (y.error("13"), !1) : /^[0-9a-zA-Z]{4,}$/.test(b) ? (a(".errorCaptcha_code").html(""), !0) : (y.error("12"), !1)
				},
				captcha: function() {
					return /^\s*$/.test(p.val()) ? (y.error("14"), !1) : (a(".errorCaptcha").html(""), !0)
				},
				validate: function() {
					return !(a(".errorAccount .error").length > 0) && (this.account(),
						this.pwd(),
						this.repwd(),
						this.captcha_code(),
						this.captcha(),
						g.find(".chk")[0].checked ? !g.find(".error").length : (a(".errorCaptcha").html("<p>请确认已阅读相关协议政策</p>"), !1))
				},
				validateRecover: function(b) {
					return !(a(".errorAccount .error").length > 0) && (this.account("recover"),
						this.captcha_code(),
						b && (this.captcha(),
							this.pwd(),
							this.repwd()), !g.find(".error").length)
				}
			},
			z = {
				getPicCode: function() {
					var b = i.val();
					a.getScript(s + "/captcha/pic/show?mobile=" + b + "&callback=response.getEmailCaptCode")
				},
				getPicCaptcha: function() {
					m.attr("src", "//" + "captcha.lenovo.com.cn" + "/img?" + (new Date).getTime())
				},
				getMobileCodeForRegist: function() {
					f = 0,
						clearInterval(e),
						o.removeAttr("disabled").html("获取手机验证码"),
						A()
				},
				getMobileCodeForRecover: function() {
					f = 0,
						clearInterval(e),
						o.removeAttr("disabled").html("获取手机验证码"),
						A("c")
				}
			},
			A = function(b) {
				if(!(a(".errorAccount .error").length > 0 || (y.captcha_code(),
						a(".errorCaptcha_code .error").length > 0))) {
					var c = i.val(),
						d = l.val();
					/^\s*$/.test(c) || C.isDefault && a(".errorAccount .error").length || g.find(".tip .error").length || "disabled" != o.attr("disabled") && (b ? a.getScript(s + "/captcha/ecssend?mobile=" + c + "&piccode=" + d + "&callback=response.getMobileCaptCode") : a.getScript(s + "/captcha/cansend?mobile=" + c + "&piccode=" + d + "&callback=response.getMobileCaptCode"))
				}
			},
			B = {
				authAccount: function(b) {
					"1" == b ? y.error("6") : a(".errorAccount").html("")
				},
				authAccountRecover: function(b) {
					"0" == b ? y.error("7") : a(".errorAccount").html("")
				},
				getEmailCaptCode: function(a) {
					var b = "data:image/png;base64," + a;
					m.attr("src", b)
				},
				getMobileCaptCode: function(b) {
					"0" != b.ret ? (a(".errorCaptcha_code").html("<p>" + b.msg + "</p>"),
						z.getPicCaptcha()) : (o.attr("disabled", "disabled").html("60秒后重新获取"),
						e = setInterval(function() {
							60 == f ? (clearInterval(e),
								o.removeAttr("disabled").html("获取手机验证码")) : (o.html(60 - f + "秒后重新获取"),
								f++)
						}, 1e3))
				}
			},
			C = {
				submit: function() {
					var d = {
						account: i.val(),
						password: j.val(),
						captcha: p.val(),
						ticket: q
					};
					y.validate() && (i.attr("disabled", "disabled"),
						j.attr("disabled", "disabled"),
						k.attr("disabled", "disabled"),
						p.attr("disabled", "disabled"),
						l.attr("disabled", "disabled"),
						r.attr("disabled", "disabled"),
						a(".errorCaptcha").html('<p class="error">正在注册，请稍后...</p>'),
						b.simulateFormSubmit("https://reg.lenovo.com.cn" + "/auth/v3/doregist", d, function(d) {
							var e = d.ret,
								f = b.getDomain(passport.loginRedirect || document.URL);
							if(i.removeAttr("disabled"),
								j.removeAttr("disabled"),
								k.removeAttr("disabled"),
								p.removeAttr("disabled"),
								r.removeAttr("disabled"),
								l.removeAttr("disabled", "disabled"),
								"0" == e) {
								c.lidlogin(d.tgt, i.val());
								var h = encodeURIComponent(d["cerpreg-passport"]);
								/lenovo\.com\.cn|lenovouat\.cn/.test(f) ? (v(),
									passport.loginAction(h)) : a.getScript("//reg." + f + "/auth/set_cookie?cookie=" + h + "&domain=" + f, function() {
									v(),
										passport.loginAction(h)
								})
							} else
								g.find(".errorCaptcha").html('<p class="error">' + d.msg + "</p>")
						}, function() {
							i.removeAttr("disabled"),
								j.removeAttr("disabled"),
								k.removeAttr("disabled"),
								p.removeAttr("disabled"),
								r.removeAttr("disabled"),
								a(".errorCaptcha").html('<p class="error">注册超时,请稍后重试</p>')
						}))
				},
				init: function(c) {
					if(!(q = "string" == typeof c ? c : c.ticket))
						throw new Error("缺少ticket");
					a("#ppInfo").length || a("body").append('<div id="ppInfo" class="ppInfo"></div>'),
						g = a("#ppInfo"),
						h = a("#ppMask"),
						g.css("width", "429px"),
						g.css("marginLeft", "-215px"),
						g.html(w),
						h.show(),
						g.show(),
						g.find(".close").on("click", v),
						i = g.find(".account"),
						j = g.find(".pwd"),
						k = g.find(".repwd"),
						p = g.find(".captcha"),
						l = g.find(".captcha_code"),
						m = g.find(".img_captcha"),
						n = g.find(".img_captcha_tip"),
						o = g.find(".mobile_captcha"),
						r = g.find(".submit"),
						f = 0,
						clearInterval(e),
						o.removeAttr("disabled").html("获取手机验证码"),
						z.getPicCaptcha(),
						i.focus(),
						b.simulatePlaceholder(i, "rr_account_placeholder", g),
						b.simulatePlaceholder(j, "rr_pwd_placeholder", g),
						i.on("blur", y.account),
						j.on("blur", y.pwd),
						k.on("blur", y.repwd),
						l.on("blur", y.captcha_code),
						m.on("click", z.getPicCaptcha),
						n.on("click", z.getPicCaptcha),
						o.on("click", z.getMobileCodeForRegist),
						p.on("keyup", function(a) {
							13 == a.keyCode && C.submit()
						}),
						r.on("click", C.submit)
				},
				hide: function() {
					v()
				}
			},
			D = {
				submit: function() {
					var b = a("#ppInfo .account").val(),
						c = a("#ppInfo .captcha").val(),
						d = a("#ppInfo .captcha_code").val(),
						e = a("#ppInfo .pwd").val();
					/^(?:1[34578]\d{9})$/i.test(b) ? y.validateRecover("phone") && a.getScript(s + "/pwd/updatepass?account=" + b + "&mcaptcha=" + c + "&password=" + e + "&callback=recover.submitResponse") : y.validateRecover() && a.getScript(s + "/pwd/findPassword?account=" + b + "&captcha=" + d + "&callback=recover.submitResponse")
				},
				submitResponse: function(b) {
					var c = b.ret,
						d = a("#ppInfo .account").val();
					if(0 == c) {
						if(a(".password_one").hide(),
							g.css("marginLeft", "-465px"),
							/^1[34578]\d{9}$/.test(d))
							a(".password_cont h1").html("恭喜您，重置密码成功！"),
							a(".password_btn a").html("请登录").on("click", function() {
								g.hide(),
									a(".ppWrapper").show(),
									a(".ppWrapper .login_main").find(".tip").html(""),
									a(".ppWrapper .login_title").find("h3").eq(0).hasClass("now") ? a(".pwd_placeholder,.account_placeholder").show() : a(".mcode_placeholder").show()
							}),
							a(".password_main").hide();
						else {
							var e = "http://mail." + d.split("@")[1];
							a(".password_cont h1").html("恭喜您，重置链接已经发送到您的" + d + "邮箱，点击邮箱中的链接进行密码重置"),
								a(".password_btn a").attr("href", e)
						}
						g.css("width", "930"),
							a(".password_two").show()
					} else
						/^1[34578]\d{9}$/.test(d) ? g.find(".errorRepwd").html('<p class="error">' + b.msg + "</p>") : g.find(".errorCaptcha_code").html('<p class="error">' + b.msg + "</p>")
				},
				init: function() {
					a("#ppInfo").length || a("body").append('<div id="ppInfo" class="ppInfo"></div>'),
						g = a("#ppInfo"),
						h = a("#ppMask"),
						g.css("width", "460px"),
						g.css("marginLeft", "-230px"),
						g.html(x),
						h.show(),
						g.show(),
						i = g.find(".account"),
						p = g.find(".captcha"),
						l = g.find(".captcha_code"),
						j = g.find(".pwd"),
						k = g.find(".repwd"),
						m = g.find(".img_captcha"),
						n = g.find(".img_captcha_tip"),
						o = g.find(".mobile_captcha").removeAttr("disabled").html("获取手机验证码"),
						f = 0,
						clearInterval(e),
						z.getPicCaptcha(),
						b.simulatePlaceholder(i, "rr_account_placeholder", g),
						setTimeout(function() {
							i.focus()
						}, 500),
						i.on("blur", function() {
							y.account("recover")
						}),
						m.on("click", z.getPicCaptcha),
						n.on("click", z.getPicCaptcha),
						o.on("click", z.getMobileCodeForRecover),
						j.on("blur", y.pwd),
						k.on("blur", y.repwd),
						l.on("keyup", function(a) {
							y.captcha_code(),
								13 == a.keyCode && D.submit()
						}),
						p.on("keyup", function(a) {
							13 == a.keyCode && D.submit()
						}),
						g.find(".submit").on("click", D.submit),
						g.find(".close").on("click", v)
				},
				hide: function() {
					v()
				}
			};
		window.regist = C,
			window.recover = D,
			window.response = B
	})
}(jQuery);

//---------------------------------------------人生苦短,及时行乐---------------------------------------------
function openlogin(a) {
	logobj.showlogin(function() {
		window.location.href = a
	})
}

function navTopDown() {
	$(".top_title").bind("mouseenter", function() {
			$(this).siblings("ul").stop(!0, !0).slideDown(300),
				$(this).find("a").removeClass(".top_down").addClass("top_up")
		}),
		$(".top_link").bind("mouseleave", function() {
			$(this).find("ul").stop(!0, !0).slideUp(300),
				$(this).find(".top_title").find("a").removeClass("top_up").addClass("top_down")
		}),
		$(".top_phone_title").bind("mouseenter", function() {
			$(this).siblings("ul").stop(!0, !0).slideDown(300),
				$(this).find("a").removeClass(".top_downs").addClass("top_ups")
		}),
		$(".top_phone").bind("mouseleave", function() {
			$(this).find("ul").stop(!0, !0).slideUp(300),
				$(this).find(".top_phone_title").find("a").removeClass("top_ups").addClass("top_downs")
		})
}

function getcartcount() {
	$.ajax({
		url: "//buy.lenovo.com.cn" + "/getshoppingcartcount.jhtml",
		dataType: "jsonp",
		async: !1,
		type: "get",
		jsonp: "callbackparam",
		success: function(a) {
			0 == a.rc && $("#top_cart_count").text(a.count)
		},
		error: function(a, b, c) {}
	})
}

function rightBar() {
	$("#rightbar").css({
			right: "-36px",
			"margin-right": "0px"
		}),
		$("#rightIcon").show(),
		$("#rightIcon").bind("mouseenter", function() {
			$(this).stop(!0, !0).animate({
				right: "-16px"
			}, 0, function() {
				$("#rightbar").stop(!0, !0).animate({
					right: "0px",
					"margin-right": "0px"
				}, 0)
			})
		}),
		$("#rightbar").bind("mouseleave", function() {
			$(this).stop(!0, !0).animate({
				right: "-36px",
				"margin-right": "0px"
			}, 0, function() {
				$("#rightIcon").stop(!0, !0).animate({
					right: "0px"
				}, 0)
			})
		})
}

function noRightBar() {
	$("#rightbar").css({
			right: "50%",
			"margin-right": "-650px"
		}),
		$("#rightIcon").hide(),
		$("#rightIcon").unbind("mouseenter"),
		$("#rightbar").unbind("mouseleave")
}

function miniBar() {
	($(window).width() - 1200) / 2 < 50 ? rightBar() : noRightBar(),
		$(window).resize(function() {
			($(window).width() - 1200) / 2 < 50 ? rightBar() : noRightBar()
		})
}

function zixun() {
	if(passport.isLogin()) {
		var a = "http://www.lenovo.com.cn/chat.html?u=" + passport.cookie.loginName;
		window.open(a)
	} else {
		var a = "http://www.lenovo.com.cn/chat.html?u=" + encodeURIComponent("匿名用户");
		window.open(a)
	}
}
$(function() {
	var a = "e40e7004-4c8a-4963-8564-31271a8337d8";
	passport.init({
			ticket: a,
			drawUserInfo: function() {
				$(".top_loginbtn").hide(),
					$(".top_regist").hide(),
					$(".top_usercenter").show(),
					$(".top_phone_title").html(passport.cookie.loginName + '<a href="#" class=" top_usepng top_downs"></a>').parent().show()
			},
			logout: function() {
				$(".top_loginbtn").show(),
					$(".top_regist").show(),
					$(".top_usercenter").hide(),
					$(".top_username").hide(),
					$(".top_phone").hide()
			}
		}),
		$("body").delegate(".login", "click", function() {
			passport.show()
		}).delegate(".logout", "click", function() {
			passport.doLogout()
		}).delegate(".regist", "click", function() {
			passport.hide(),
				regist.init(a)
		}).delegate(".forgetPwd", "click", function() {
			passport.hide(),
				recover.init(a)
		})
});
var logobj = {
	showlogin: function(a) {
		passport.show(),
			"function" == typeof a && (console.log("您在不恰当的位置设置了登陆后的跳转,为了保证安全，页面将会对您的设置进行延迟跳转(2s)"),
				passport.login = function() {
					setTimeout(a, 2e3)
				}
			)
	}
};
$(function() {
	navTopDown(),
		getcartcount()
});
var Bar = function() {
	var a = {};
	return a.rightbar = function() {
			var a = $(".rightbar_hover"),
				b = $("#totop");
			a.hover(function() {
					$(this).addClass("active")
				}, function() {
					$(this).removeClass("active")
				}),
				b.click(function() {
					$("html,body").animate({
						scrollTop: 0
					}, 500)
				})
		},
		a
}(jQuery);
$(function() {
	Bar.rightbar(),
		miniBar()
});
var c2cshare = {
	s_code: "",
	env: document.domain.indexOf("uat") > -1 ? "test" : "pro",
	isApp: /lenovomallapp/i.test(navigator.userAgent),
	setCookie: function(a, b, c) {
		if(c = $.extend({
				path: "/"
			}, c || {}),
			"number" == typeof c.expires) {
			var d = c.expires,
				e = c.expires = new Date;
			e.setMilliseconds(e.getMilliseconds() + 864e5 * d)
		}
		return document.cookie = [encodeURIComponent(a), "=", this.stringifyCookieValue(b, c), c.expires ? "; expires=" + c.expires.toUTCString() : "", c.path ? "; path=" + c.path : "", c.domain ? "; domain=" + c.domain : "", c.secure ? "; secure" : ""].join("")
	},
	stringifyCookieValue: function(a, b) {
		return encodeURIComponent(b.json ? JSON.stringify(a) : String(a))
	},
	getRequest: function(a) {
		var b = new RegExp("(^|&)" + a + "=([^&]*)(&|$)", "i"),
			c = window.location.search.substr(1).match(b);
		return null != c ? decodeURIComponent(c[2]) : null
	},
	share: function() {
		var a = window.location.href;
		if(-1 != a.indexOf("sharecode="))
			for(var b = a.split("&"), c = 0; c < b.length; c++)
				if(-1 != b[c].indexOf("sharecode=")) {
					if(this.s_code = b[c].substr(b[c].indexOf("sharecode=") + 10),
						this.s_code) {
						!0;
						var d = this.getRequest("promotionChannels") || "",
							e = this.getRequest("promotionName") || "",
							f = this.s_code,
							g = "test" == this.env ? ".lenovouat.cn" : ".lenovo.com.cn";
						this.setCookie("c2clenovo", '{"promotionName":"' + e + '","promotionType":"1","promotionChannels":"' + d + '","memberId":"' + f + '", "type": "1"}', {
								domain: g,
								expires: 15
							}),
							this.setCookie("wi", "", {
								domain: g,
								expires: -1
							}),
							this.setCookie("cid", "", {
								domain: g,
								expires: -1
							}),
							this.setCookie("target", "", {
								domain: g,
								expires: -1
							}),
							this.setCookie("channel", "", {
								domain: g,
								expires: -1
							}),
							this.setCookie("source", "", {
								domain: g,
								expires: -1
							});
						try {
							$.get("/api/c2c/sharedby.do", {
								sharecode: this.s_code,
								sourceurl: a,
								promotionChannels: d,
								promotionName: e,
								promotionType: "1"
							}, function(a) {})
						} catch(h) {
							pd.log(pd.fail_msg.replace("_me", "share").replace("_sv", "sharedby.do") + h.message, "warn")
						}
					}
					break
				}
	}
};
$(function() {
	c2cshare.share()
});